package stream;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.stream.Stream;

public class StreamMap {
    public static void main(String[] args){
        List<String> list=new ArrayList<>();
        Collections.addAll(list,"11","22","33","44");
        /**
         * R apply(T t)
         * 入参是 T 类型
         * 出参是 R 类型
         * T---R
         */
        Stream<Integer> integerStream = list.stream().map(s -> Integer.parseInt(s));
        integerStream.forEach(x->System.out.println(x+10));
    }
}
